from typing import List, Optional
from pydantic import BaseModel, Field

class RoadModel(BaseModel):
    """Information about a road."""
    roadName: Optional[str] = Field(default=None, description="道路名称")
    roadSide: Optional[str] = Field(default=None, description="道路路侧")
    dimmingValue: Optional[int] = Field(default=None, description="开灯时默认为100,关灯时默认为0", ge=0, le=100)

class LamppostModel(BaseModel):
    """Information about pole."""
    lamppostCode: Optional[str] = Field(default=None, description="灯杆编号")
    dimmingValue: Optional[int] = Field(default=None, description="开灯时默认为100,关灯时默认为0", ge=0, le=100)